

s = 0
a = 2
temp = 0

try:
     n = int(input("请输入一个整数:"))
     for i in range(n):
          temp = a * 10 ** i + temp
          s += temp
except Exception:
     print("错误提示:输入的数据类型不正确")

print(s)